|
|
|
|
|
|
|
When you multiply this matrix by a generic point [x, y, z, w, 1], the result is [x + Tx, y + Ty, z + Tz, w + Tw, 1], as it should be. |
|
|
|
|
|
|
|
|
Four-dimensional scaling is also a simple extension of the two- and three-dimensional operations. The transformation matrix representing scaling by factors of Sx, Sy, Sz, and Sw in the X, Y, Z, and W directions is: |
|
|
|
|
|
|
|
|
When you multiply this matrix by the point [x, y, z, w, 1], the result is [x * Sx, y * Sy, z * Sz, w*Sw, 1]. |
|
|
|
|
|
|
|
|
In two dimensions, you can reflect a point across a line. In the simplest reflections, that line is either the X or Y coordinate axis. For example, to reflect a point across the X axis, leave the point's X coordinate unchanged and reverse the sign of its Y coordinate. You can use translations and rotations to reflect a point across a line other than one of the coordinate axes. |
|
|
|
|
|
|
|
|
In three dimensions, you can reflect a point across a plane. In the simplest reflections, that plane is one of the X-Y, X-Z, or Y-Z coordinate planes. For example, to reflect a point across the X-Y plane, leave the point's X and Y coordinates unchanged and reverse the sign of its Z coordinate. You can use translations and rotations to reflect a point across a plane other than one of the coordinate planes. |
|
|
|
|
|
|
|
|
In four dimensions, you can reflect a point across a three-dimensional space. In the simplest reflections, that space is one of the four coordinate spaces: X-Y-Z, X-Y-W, X-Z-W, or Y-Z-W. For example, to reflect a point across the Y-Z-W space, leave the point's Y, Z, and W coordinates unchanged and reverse the sign of its X coordinate. The transformation matrix that represents this reflection is shown below. |
|
|
|
|
|